﻿<UserControl
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
    xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
    xmlns:i="clr-namespace:System.Windows.Interactivity;assembly=System.Windows.Interactivity" 
    xmlns:ec="clr-namespace:Microsoft.Expression.Interactivity.Core;assembly=Microsoft.Expression.Interactions"
    xmlns:system="clr-namespace:System;assembly=mscorlib"
    xmlns:phone="clr-namespace:Microsoft.Phone.Controls;assembly=Microsoft.Phone"
    x:Class="TakePhotoTogether.View.AppBar"
    mc:Ignorable="d"
    d:DesignHeight="480">

    <UserControl.Resources>
        <Style x:Key="AppBarButtonFlashOn" TargetType="Button">
            <Setter Property="Background" Value="Transparent"/>
            <Setter Property="BorderBrush" Value="{StaticResource PhoneForegroundBrush}"/>
            <Setter Property="Foreground" Value="{StaticResource PhoneForegroundBrush}"/>
            <Setter Property="BorderThickness" Value="{StaticResource PhoneBorderThickness}"/>
            <Setter Property="FontFamily" Value="{StaticResource PhoneFontFamilySemiBold}"/>
            <Setter Property="FontSize" Value="{StaticResource PhoneFontSizeMedium}"/>
            <Setter Property="Padding" Value="10,5,10,6"/>
            <Setter Property="Template">
                <Setter.Value>
                    <ControlTemplate TargetType="Button">
                        <Grid x:Name="grid" HorizontalAlignment="Center" VerticalAlignment="Center">
                            <VisualStateManager.VisualStateGroups>
                                <VisualStateGroup x:Name="CommonStates">
                                    <VisualState x:Name="Pressed">
                                        <Storyboard>
                                            <ColorAnimation Duration="0" To="{StaticResource PhoneAccentColor}" Storyboard.TargetProperty="(Shape.Fill).(SolidColorBrush.Color)" Storyboard.TargetName="ellipse" d:IsOptimized="True"/>
                                        </Storyboard>
                                    </VisualState>
                                    <VisualState x:Name="Normal"/>
                                    <VisualState x:Name="Disabled">
                                        <Storyboard>
                                            <DoubleAnimation Duration="0" To="0.3" Storyboard.TargetProperty="(UIElement.Opacity)" Storyboard.TargetName="grid" d:IsOptimized="True"/>
                                        </Storyboard>
                                    </VisualState>
                                    <VisualState x:Name="MouseOver"/>
                                </VisualStateGroup>
                                <VisualStateGroup x:Name="FocusStates">
                                    <VisualState x:Name="Focused"/>
                                </VisualStateGroup>
                            </VisualStateManager.VisualStateGroups>
                            <TextBlock HorizontalAlignment="Left" TextWrapping="Wrap" Text="{Binding Path=LocalizedResources.AppBar_Flash, Source={StaticResource LocalizedStrings}}" VerticalAlignment="Center" FontSize="13.333" Foreground="White" Margin="60,13,0,17" FontFamily="Segoe WP"/>
                            <Grid Margin="0" HorizontalAlignment="Left" VerticalAlignment="Top" Width="48" Height="48">
                                <Ellipse x:Name="ellipse" HorizontalAlignment="Center" Height="48" Stroke="White" VerticalAlignment="Center" Width="48" StrokeThickness="3" Margin="0" Fill="#00E51400"/>
                                <Path x:Name="On" Data="F1M731.001,752.998L722,763L730,763L713.999,779L720,766L713,766L721,752.998z" Fill="White" Stretch="Fill" Margin="15.666,11.666,14.334,10.332" UseLayoutRounding="False" HorizontalAlignment="Center" VerticalAlignment="Center" Width="18" Height="26.002"/>
                            </Grid>
                        </Grid>
                    </ControlTemplate>
                </Setter.Value>
            </Setter>
        </Style>
        <Style x:Key="AppBarButtonFlashAuto" TargetType="Button">
            <Setter Property="Background" Value="Transparent"/>
            <Setter Property="BorderBrush" Value="{StaticResource PhoneForegroundBrush}"/>
            <Setter Property="Foreground" Value="{StaticResource PhoneForegroundBrush}"/>
            <Setter Property="BorderThickness" Value="{StaticResource PhoneBorderThickness}"/>
            <Setter Property="FontFamily" Value="{StaticResource PhoneFontFamilySemiBold}"/>
            <Setter Property="FontSize" Value="{StaticResource PhoneFontSizeMedium}"/>
            <Setter Property="Padding" Value="10,5,10,6"/>
            <Setter Property="Template">
                <Setter.Value>
                    <ControlTemplate TargetType="Button">
                        <Grid x:Name="grid" HorizontalAlignment="Center" VerticalAlignment="Center">
                            <VisualStateManager.VisualStateGroups>
                                <VisualStateGroup x:Name="CommonStates">
                                    <VisualState x:Name="Pressed">
                                        <Storyboard>
                                            <ColorAnimation Duration="0" To="{StaticResource PhoneAccentColor}" Storyboard.TargetProperty="(Shape.Fill).(SolidColorBrush.Color)" Storyboard.TargetName="ellipse" d:IsOptimized="True"/>
                                        </Storyboard>
                                    </VisualState>
                                    <VisualState x:Name="Normal"/>
                                    <VisualState x:Name="Disabled">
                                        <Storyboard>
                                            <DoubleAnimation Duration="0" To="0.3" Storyboard.TargetProperty="(UIElement.Opacity)" Storyboard.TargetName="grid" d:IsOptimized="True"/>
                                        </Storyboard>
                                    </VisualState>
                                    <VisualState x:Name="MouseOver"/>
                                </VisualStateGroup>
                                <VisualStateGroup x:Name="FocusStates">
                                    <VisualState x:Name="Focused"/>
                                </VisualStateGroup>
                            </VisualStateManager.VisualStateGroups>
                            <TextBlock HorizontalAlignment="Left" TextWrapping="Wrap" Text="{Binding Path=LocalizedResources.AppBar_Flash, Source={StaticResource LocalizedStrings}}" VerticalAlignment="Center" FontSize="13.333" Foreground="White" Margin="60,13,0,17" FontFamily="Segoe WP"/>
                            <Grid Margin="0" HorizontalAlignment="Left" VerticalAlignment="Top" Width="48" Height="48">
                                <Ellipse x:Name="ellipse" HorizontalAlignment="Center" Height="48" Stroke="White" VerticalAlignment="Center" Width="48" StrokeThickness="3" Margin="0" Fill="#00E51400"/>
                                <Path x:Name="Auto" Data="F1M680.2861,771.3887L682.4781,771.3887L681.8601,769.3047L681.5991,768.3577L681.3601,767.4097L681.3311,767.4097L681.1081,768.3667L680.8751,769.3297z M682.8021,772.9847L679.9631,772.9847L679.2561,775.6237L676.9461,775.6237L679.9631,765.8157L682.9051,765.8157L685.9941,775.6237L683.5671,775.6237z M681.6311,753.6317L672.6301,763.6337L680.6311,763.6337L664.6291,779.6327L670.6311,766.6327L663.6301,766.6327L671.6311,753.6317z" Fill="White" Stretch="Fill" Margin="14.321,11.667,11.315,10.333" UseLayoutRounding="False" HorizontalAlignment="Center" VerticalAlignment="Center" Width="22.364" Height="26"/>
                            </Grid>
                        </Grid>
                    </ControlTemplate>
                </Setter.Value>
            </Setter>
        </Style>
        <Style x:Key="AppBarButtonFlashOff" TargetType="Button">
            <Setter Property="Background" Value="Transparent"/>
            <Setter Property="BorderBrush" Value="{StaticResource PhoneForegroundBrush}"/>
            <Setter Property="Foreground" Value="{StaticResource PhoneForegroundBrush}"/>
            <Setter Property="BorderThickness" Value="{StaticResource PhoneBorderThickness}"/>
            <Setter Property="FontFamily" Value="{StaticResource PhoneFontFamilySemiBold}"/>
            <Setter Property="FontSize" Value="{StaticResource PhoneFontSizeMedium}"/>
            <Setter Property="Padding" Value="10,5,10,6"/>
            <Setter Property="Template">
                <Setter.Value>
                    <ControlTemplate TargetType="Button">
                        <Grid x:Name="grid" HorizontalAlignment="Center" VerticalAlignment="Center">
                            <VisualStateManager.VisualStateGroups>
                                <VisualStateGroup x:Name="CommonStates">
                                    <VisualState x:Name="Pressed">
                                        <Storyboard>
                                            <ColorAnimation Duration="0" To="{StaticResource PhoneAccentColor}" Storyboard.TargetProperty="(Shape.Fill).(SolidColorBrush.Color)" Storyboard.TargetName="ellipse" d:IsOptimized="True"/>
                                        </Storyboard>
                                    </VisualState>
                                    <VisualState x:Name="Normal"/>
                                    <VisualState x:Name="Disabled">
                                        <Storyboard>
                                            <DoubleAnimation Duration="0" To="0.3" Storyboard.TargetProperty="(UIElement.Opacity)" Storyboard.TargetName="grid" d:IsOptimized="True"/>
                                        </Storyboard>
                                    </VisualState>
                                    <VisualState x:Name="MouseOver"/>
                                </VisualStateGroup>
                                <VisualStateGroup x:Name="FocusStates">
                                    <VisualState x:Name="Focused"/>
                                </VisualStateGroup>
                            </VisualStateManager.VisualStateGroups>
                            <TextBlock HorizontalAlignment="Left" TextWrapping="Wrap" Text="{Binding Path=LocalizedResources.AppBar_Flash, Source={StaticResource LocalizedStrings}}" VerticalAlignment="Center" FontSize="13.333" Foreground="White" Margin="60,13,0,17" FontFamily="Segoe WP"/>
                            <Grid Margin="0" HorizontalAlignment="Left" VerticalAlignment="Top" Width="48" Height="48">
                                <Ellipse x:Name="ellipse" HorizontalAlignment="Center" Height="48" Stroke="White" VerticalAlignment="Center" Width="48" StrokeThickness="3" Margin="0" Fill="#00E51400"/>
                                <Path x:Name="Off" Data="F1M773,770L775,768L782,775L780,777z M757.5,754L761,754L764.75,757.75L763.25,759.75z M779.001,752.998L770,763L778,763L761.999,779L768,766L761,766L769,752.998z" Fill="White" Stretch="Fill" Margin="10.915,11.666,12.585,10.332" UseLayoutRounding="False" HorizontalAlignment="Center" VerticalAlignment="Center" Width="24.5" Height="26.002"/>
                            </Grid>
                        </Grid>
                    </ControlTemplate>
                </Setter.Value>
            </Setter>
        </Style>
        <Style x:Key="AppButtonCameraRear" TargetType="Button">
            <Setter Property="Background" Value="Transparent"/>
            <Setter Property="BorderBrush" Value="{StaticResource PhoneForegroundBrush}"/>
            <Setter Property="Foreground" Value="{StaticResource PhoneForegroundBrush}"/>
            <Setter Property="BorderThickness" Value="{StaticResource PhoneBorderThickness}"/>
            <Setter Property="FontFamily" Value="{StaticResource PhoneFontFamilySemiBold}"/>
            <Setter Property="FontSize" Value="{StaticResource PhoneFontSizeMedium}"/>
            <Setter Property="Padding" Value="10,5,10,6"/>
            <Setter Property="Template">
                <Setter.Value>
                    <ControlTemplate TargetType="Button">
                        <Grid x:Name="grid" HorizontalAlignment="Center" VerticalAlignment="Center">
                            <VisualStateManager.VisualStateGroups>
                                <VisualStateGroup x:Name="FocusStates">
                                    <VisualState x:Name="Focused"/>
                                </VisualStateGroup>
                                <VisualStateGroup x:Name="CommonStates">
                                    <VisualState x:Name="Pressed">
                                        <Storyboard>
                                            <ColorAnimation Duration="0" To="{StaticResource PhoneAccentColor}" Storyboard.TargetProperty="(Shape.Fill).(SolidColorBrush.Color)" Storyboard.TargetName="ellipse" d:IsOptimized="True"/>
                                        </Storyboard>
                                    </VisualState>
                                    <VisualState x:Name="Normal"/>
                                    <VisualState x:Name="Disabled">
                                        <Storyboard>
                                            <DoubleAnimation Duration="0" To="0.3" Storyboard.TargetProperty="(UIElement.Opacity)" Storyboard.TargetName="grid" d:IsOptimized="True"/>
                                        </Storyboard>
                                    </VisualState>
                                    <VisualState x:Name="MouseOver"/>
                                </VisualStateGroup>
                            </VisualStateManager.VisualStateGroups>
                            <TextBlock HorizontalAlignment="Left" TextWrapping="Wrap" Text="{Binding Path=LocalizedResources.AppBar_Front, Source={StaticResource LocalizedStrings}}" VerticalAlignment="Center" FontSize="13.333" Foreground="White" Margin="60,-15,0,0" FontFamily="Segoe WP"/>
                            <TextBlock HorizontalAlignment="Left" TextWrapping="Wrap" Text="{Binding Path=LocalizedResources.AppBar_Camera, Source={StaticResource LocalizedStrings}}" VerticalAlignment="Center" FontSize="13.333" Foreground="White" Margin="60,11,0,0" FontFamily="Segoe WP"/>
                            <Grid x:Name="grid1" Margin="0" HorizontalAlignment="Left" VerticalAlignment="Top" Width="48" Height="48">
                                <Ellipse x:Name="ellipse" HorizontalAlignment="Center" Height="48" Stroke="White" VerticalAlignment="Center" Width="48" StrokeThickness="3" Margin="0" Fill="#00E51400"/>
                                <Path x:Name="path" Data="F1M808.2109,759.3159C807.6879,759.3159,807.2639,759.8809,807.2639,760.5789C807.2639,761.2759,807.6879,761.8419,808.2109,761.8419C808.7329,761.8419,809.1579,761.2759,809.1579,760.5789C809.1579,759.8809,808.7329,759.3159,808.2109,759.3159 M811.0529,757.4209C811.0529,755.7649,812.5539,754.2629,814.2109,754.2629L817.9999,754.2629C819.1489,754.2629,820.2219,754.9839,820.7729,755.9779C820.4149,756.5869,820.2109,757.2959,820.2109,758.0529C820.2109,759.3609,820.8219,760.5259,821.7759,761.2779C820.8219,761.4439,819.9979,761.8329,819.2889,762.3779C818.5489,761.6559,817.5369,761.2109,816.4209,761.2109C814.1539,761.2109,812.3159,763.0489,812.3159,765.3159C812.3159,767.2829,813.6989,768.9279,815.5469,769.3279C815.2599,770.5389,815.0899,771.6799,814.9879,772.5789L807.8949,772.5789C806.1499,772.5789,804.7359,771.1659,804.7359,769.4209L804.7359,760.5789C804.7359,758.8349,806.1499,757.4209,807.8949,757.4209z M826.8419,762.4739C826.8419,762.4739,833.1579,761.8419,832.9999,774.7889L830.9469,775.2639C830.9469,775.2639,830.6319,770.5259,829.3679,767.9999L829.3679,775.8949C829.3679,775.8949,827.1579,776.9609,824.6319,776.9809C822.1059,776.9999,819.7359,775.8949,819.7359,775.8949L819.7359,767.9999C818.4739,770.5259,818.1579,775.2639,818.1579,775.2639L816.1059,774.7889C815.9469,761.8419,822.2639,762.4739,822.2639,762.4739z M824.3159,754.8949C826.0609,754.8949,827.4739,756.3089,827.4739,758.0529C827.4739,759.7969,826.0609,761.2109,824.3159,761.2109C822.5709,761.2109,821.1579,759.7969,821.1579,758.0529C821.1579,756.3089,822.5709,754.8949,824.3159,754.8949" Fill="White" Stretch="Fill" Margin="9.867,13.307,9.867,11.975" UseLayoutRounding="False" Width="28.266" Height="22.718" HorizontalAlignment="Center" VerticalAlignment="Center">
                                    <Path.Clip>
                                        <RectangleGeometry RadiusY="0" RadiusX="0" Rect="0,-0.836000000000013,1512.836,1512.836">
                                            <RectangleGeometry.Transform>
                                                <MatrixTransform Matrix="1,0,0,1,-804.735900878906,-754.262878417969"/>
                                            </RectangleGeometry.Transform>
                                        </RectangleGeometry>
                                    </Path.Clip>
                                </Path>
                            </Grid>
                        </Grid>
                    </ControlTemplate>
                </Setter.Value>
            </Setter>
        </Style>
        <Style x:Key="AppButtonCameraFront" TargetType="Button">
            <Setter Property="Background" Value="Transparent"/>
            <Setter Property="BorderBrush" Value="{StaticResource PhoneForegroundBrush}"/>
            <Setter Property="Foreground" Value="{StaticResource PhoneForegroundBrush}"/>
            <Setter Property="BorderThickness" Value="{StaticResource PhoneBorderThickness}"/>
            <Setter Property="FontFamily" Value="{StaticResource PhoneFontFamilySemiBold}"/>
            <Setter Property="FontSize" Value="{StaticResource PhoneFontSizeMedium}"/>
            <Setter Property="Padding" Value="10,5,10,6"/>
            <Setter Property="Template">
                <Setter.Value>
                    <ControlTemplate TargetType="Button">
                        <Grid x:Name="grid" HorizontalAlignment="Center" VerticalAlignment="Center">
                            <VisualStateManager.VisualStateGroups>
                                <VisualStateGroup x:Name="FocusStates">
                                    <VisualState x:Name="Focused"/>
                                </VisualStateGroup>
                                <VisualStateGroup x:Name="CommonStates">
                                    <VisualState x:Name="Pressed">
                                        <Storyboard>
                                            <ColorAnimation Duration="0" To="{StaticResource PhoneAccentColor}" Storyboard.TargetProperty="(Shape.Fill).(SolidColorBrush.Color)" Storyboard.TargetName="ellipse" d:IsOptimized="True"/>
                                            <ColorAnimation Duration="0" To="White" Storyboard.TargetProperty="(Shape.Fill).(SolidColorBrush.Color)" Storyboard.TargetName="path" d:IsOptimized="True"/>
                                        </Storyboard>
                                    </VisualState>
                                    <VisualState x:Name="Normal"/>
                                    <VisualState x:Name="Disabled">
                                        <Storyboard>
                                            <DoubleAnimation Duration="0" To="0.3" Storyboard.TargetProperty="(UIElement.Opacity)" Storyboard.TargetName="grid" d:IsOptimized="True"/>
                                        </Storyboard>
                                    </VisualState>
                                    <VisualState x:Name="MouseOver"/>
                                </VisualStateGroup>
                            </VisualStateManager.VisualStateGroups>
                            <TextBlock HorizontalAlignment="Left" TextWrapping="Wrap" Text="{Binding Path=LocalizedResources.AppBar_Front, Source={StaticResource LocalizedStrings}}" VerticalAlignment="Center" FontSize="13.333" Foreground="White" Margin="60,-15,0,0" FontFamily="Segoe WP"/>
                            <TextBlock HorizontalAlignment="Left" TextWrapping="Wrap" Text="{Binding Path=LocalizedResources.AppBar_Camera, Source={StaticResource LocalizedStrings}}" VerticalAlignment="Center" FontSize="13.333" Foreground="White" Margin="60,11,0,0" FontFamily="Segoe WP"/>
                            <Grid x:Name="grid1" Margin="0" HorizontalAlignment="Left" VerticalAlignment="Top" Width="48" Height="48">
                                <Ellipse x:Name="ellipse" HorizontalAlignment="Center" Height="48" Stroke="White" VerticalAlignment="Center" Width="48" StrokeThickness="3" Margin="0" Fill="White"/>
                                <Path x:Name="path" Data="F1M808.2109,759.3159C807.6879,759.3159,807.2639,759.8809,807.2639,760.5789C807.2639,761.2759,807.6879,761.8419,808.2109,761.8419C808.7329,761.8419,809.1579,761.2759,809.1579,760.5789C809.1579,759.8809,808.7329,759.3159,808.2109,759.3159 M811.0529,757.4209C811.0529,755.7649,812.5539,754.2629,814.2109,754.2629L817.9999,754.2629C819.1489,754.2629,820.2219,754.9839,820.7729,755.9779C820.4149,756.5869,820.2109,757.2959,820.2109,758.0529C820.2109,759.3609,820.8219,760.5259,821.7759,761.2779C820.8219,761.4439,819.9979,761.8329,819.2889,762.3779C818.5489,761.6559,817.5369,761.2109,816.4209,761.2109C814.1539,761.2109,812.3159,763.0489,812.3159,765.3159C812.3159,767.2829,813.6989,768.9279,815.5469,769.3279C815.2599,770.5389,815.0899,771.6799,814.9879,772.5789L807.8949,772.5789C806.1499,772.5789,804.7359,771.1659,804.7359,769.4209L804.7359,760.5789C804.7359,758.8349,806.1499,757.4209,807.8949,757.4209z M826.8419,762.4739C826.8419,762.4739,833.1579,761.8419,832.9999,774.7889L830.9469,775.2639C830.9469,775.2639,830.6319,770.5259,829.3679,767.9999L829.3679,775.8949C829.3679,775.8949,827.1579,776.9609,824.6319,776.9809C822.1059,776.9999,819.7359,775.8949,819.7359,775.8949L819.7359,767.9999C818.4739,770.5259,818.1579,775.2639,818.1579,775.2639L816.1059,774.7889C815.9469,761.8419,822.2639,762.4739,822.2639,762.4739z M824.3159,754.8949C826.0609,754.8949,827.4739,756.3089,827.4739,758.0529C827.4739,759.7969,826.0609,761.2109,824.3159,761.2109C822.5709,761.2109,821.1579,759.7969,821.1579,758.0529C821.1579,756.3089,822.5709,754.8949,824.3159,754.8949" Fill="Black" Stretch="Fill" Margin="9.867,13.307,9.867,11.975" UseLayoutRounding="False" Width="28.266" Height="22.718" HorizontalAlignment="Center" VerticalAlignment="Center">
                                    <Path.Clip>
                                        <RectangleGeometry RadiusY="0" RadiusX="0" Rect="0,-0.836000000000013,1512.836,1512.836">
                                            <RectangleGeometry.Transform>
                                                <MatrixTransform Matrix="1,0,0,1,-804.735900878906,-754.262878417969"/>
                                            </RectangleGeometry.Transform>
                                        </RectangleGeometry>
                                    </Path.Clip>
                                </Path>
                            </Grid>
                        </Grid>
                    </ControlTemplate>
                </Setter.Value>
            </Setter>
        </Style>
    </UserControl.Resources>

    <UserControl.FontFamily>
        <StaticResource ResourceKey="PhoneFontFamilyNormal"/>
    </UserControl.FontFamily>
    <UserControl.FontSize>
        <StaticResource ResourceKey="PhoneFontSizeNormal"/>
    </UserControl.FontSize>
    <UserControl.Foreground>
        <StaticResource ResourceKey="PhoneForegroundBrush"/>
    </UserControl.Foreground>

    <Grid
		x:Name="LayoutRoot">
        <i:Interaction.Triggers>
            <i:EventTrigger EventName="Loaded">
                <ec:GoToStateAction StateName="Closed"/>
            </i:EventTrigger>
        </i:Interaction.Triggers>
        <VisualStateManager.VisualStateGroups>
            <VisualStateGroup x:Name="OpenClose">
                <VisualStateGroup.Transitions>
                    <VisualTransition GeneratedDuration="0">
                        <VisualTransition.GeneratedEasingFunction>
                            <CircleEase EasingMode="EaseOut"/>
                        </VisualTransition.GeneratedEasingFunction>
                    </VisualTransition>
                </VisualStateGroup.Transitions>
                <VisualState x:Name="Open">
                    <Storyboard
						Completed="OpenStoryboard_Completed">

                        <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(FrameworkElement.Width)" Storyboard.TargetName="stackPanel">
                            <EasingDoubleKeyFrame KeyTime="0" Value="72"/>
                            <EasingDoubleKeyFrame KeyTime="0:0:0.3" Value="350">
                                <EasingDoubleKeyFrame.EasingFunction>
                                    <CircleEase EasingMode="EaseOut"/>
                                </EasingDoubleKeyFrame.EasingFunction>
                            </EasingDoubleKeyFrame>
                        </DoubleAnimationUsingKeyFrames>
                        <ColorAnimationUsingKeyFrames Storyboard.TargetProperty="(Panel.Background).(SolidColorBrush.Color)" Storyboard.TargetName="stackPanel">
                            <EasingColorKeyFrame KeyTime="0" Value="#00000000"/>
                            <EasingColorKeyFrame KeyTime="0:0:0.3" Value="Black">
                                <EasingColorKeyFrame.EasingFunction>
                                    <CircleEase EasingMode="EaseOut"/>
                                </EasingColorKeyFrame.EasingFunction>
                            </EasingColorKeyFrame>
                        </ColorAnimationUsingKeyFrames>
                        <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Opacity)" Storyboard.TargetName="AppBarButtons">
                            <EasingDoubleKeyFrame KeyTime="0" Value="0"/>
                            <EasingDoubleKeyFrame KeyTime="0:0:0.3" Value="1"/>
                        </DoubleAnimationUsingKeyFrames>
                        <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="(Control.IsHitTestVisible)" Storyboard.TargetName="AppBarButtons">
                            <DiscreteObjectKeyFrame KeyTime="0">
                                <DiscreteObjectKeyFrame.Value>
                                    <system:Boolean>True</system:Boolean>
                                </DiscreteObjectKeyFrame.Value>
                            </DiscreteObjectKeyFrame>
                        </ObjectAnimationUsingKeyFrames>
                    </Storyboard>
                </VisualState>
                <VisualState x:Name="Closed">
                    <Storyboard
						Completed="CloseStoryboard_Completed"
						RepeatBehavior="1x">
                        <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(FrameworkElement.Width)" Storyboard.TargetName="stackPanel">
                            <EasingDoubleKeyFrame KeyTime="0" Value="350"/>
                            <EasingDoubleKeyFrame KeyTime="0:0:0.2" Value="72">
                                <EasingDoubleKeyFrame.EasingFunction>
                                    <CircleEase EasingMode="EaseOut"/>
                                </EasingDoubleKeyFrame.EasingFunction>
                            </EasingDoubleKeyFrame>
                        </DoubleAnimationUsingKeyFrames>
                        <ColorAnimationUsingKeyFrames Storyboard.TargetProperty="(Panel.Background).(SolidColorBrush.Color)" Storyboard.TargetName="stackPanel">
                            <EasingColorKeyFrame KeyTime="0" Value="Black"/>
                            <EasingColorKeyFrame KeyTime="0:0:0.2" Value="#00000000">
                                <EasingColorKeyFrame.EasingFunction>
                                    <CircleEase EasingMode="EaseOut"/>
                                </EasingColorKeyFrame.EasingFunction>
                            </EasingColorKeyFrame>
                        </ColorAnimationUsingKeyFrames>
                        <DoubleAnimation Duration="0:0:0.1" To="0" Storyboard.TargetProperty="(UIElement.Opacity)" Storyboard.TargetName="AppBarButtons" d:IsOptimized="True"/>
                        <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="(Control.IsHitTestVisible)" Storyboard.TargetName="AppBarButtons">
                            <DiscreteObjectKeyFrame KeyTime="0">
                                <DiscreteObjectKeyFrame.Value>
                                    <system:Boolean>False</system:Boolean>
                                </DiscreteObjectKeyFrame.Value>
                            </DiscreteObjectKeyFrame>
                        </ObjectAnimationUsingKeyFrames>
                    </Storyboard>
                </VisualState>
            </VisualStateGroup>
        </VisualStateManager.VisualStateGroups>

        <StackPanel
			x:Name="stackPanel"
			Margin="0"
			Orientation="Horizontal"
			HorizontalAlignment="Right"
			Background="Black"
			RenderTransformOrigin="0.5,0.5"
			Width="72">
            <Grid Margin="12,0,0,0" Width="103">
                <Grid x:Name="AppBarButtons" Width="103" HorizontalAlignment="Right" VerticalAlignment="Center" Height="164" Opacity="0">
                    <Button x:Name="ButtonFlashOn" Click="ButtonFlashOn_Click"  Content="Button" VerticalAlignment="Top" Style="{StaticResource AppBarButtonFlashOn}" Margin="0,17,0,0"/>
                    <Button x:Name="ButtonFlashOff" Click="ButtonFlashOff_Click"  Content="Button" VerticalAlignment="Top" Style="{StaticResource AppBarButtonFlashOff}" Margin="0,17,0,0" Visibility="Collapsed"/>
                    <Button x:Name="ButtonFlashAuto" Click="ButtonFlashAuto_Click" Content="Button" VerticalAlignment="Top" Style="{StaticResource AppBarButtonFlashAuto}" Margin="0,17,0,0" Visibility="Collapsed"/>
                    <Button x:Name="ButtonCameraFront" Click="ButtonCameraMode_Click" Content="Button" VerticalAlignment="Top" Style="{StaticResource AppButtonCameraFront}" Margin="0,99,-15,0" Visibility="Collapsed"/>
                    <Button x:Name="ButtonCameraRear" Click="ButtonCameraMode_Click" Content="Button" VerticalAlignment="Top" Style="{StaticResource AppButtonCameraRear}" Margin="0,99,-15,0"/>
                </Grid>
                <StackPanel Orientation="Vertical" x:Name="MoreButton" Margin="-33,0,0,0" VerticalAlignment="Top" Background="#00000000" IsHitTestVisible="True" HorizontalAlignment="Left" Width="70" Height="80" Tap="MoreButton_Tap">
                    <Ellipse Fill="White" HorizontalAlignment="Left" Height="6" VerticalAlignment="Top" Width="6" Margin="37,24,17,0"/>
                    <Ellipse Fill="White" HorizontalAlignment="Left" Height="6" VerticalAlignment="Top" Width="6" Margin="37,6,17,0"/>
                    <Ellipse Fill="White" HorizontalAlignment="Left" Height="6" VerticalAlignment="Top" Width="6" Margin="37,6,17,0"/>
                </StackPanel>
            </Grid>
            <StackPanel x:Name="MenuItems" Margin="0" Orientation="Vertical">
                <StackPanel.Resources>
                    <Style TargetType="Button">
                        <Setter Property="RenderTransformOrigin" Value="0.5,0.5" />
                        <Setter Property="RenderTransform">
                            <Setter.Value>
                                <CompositeTransform />
                            </Setter.Value>
                        </Setter>
                        <Setter Property="Template">
                            <Setter.Value>
                                <ControlTemplate TargetType="Button">
                                    <TextBlock
										Text="{TemplateBinding Content}"
										Foreground="White"
										FontFamily="Segoe WP Light"
										FontSize="32" />
                                </ControlTemplate>
                            </Setter.Value>
                        </Setter>
                    </Style>
                </StackPanel.Resources>
                <Button x:Name="listBoxItem2" Content="{Binding Path=LocalizedResources.AppBar_About, Source={StaticResource LocalizedStrings}}" Margin="50,50,70,25" Click="About_Click"/>
                <Button x:Name="listBoxItem1" Content="{Binding Path=LocalizedResources.AppBar_Tutorial, Source={StaticResource LocalizedStrings}}" Margin="50,0,70,25" Click="FTU_Click"/>               
            </StackPanel>
        </StackPanel>
    </Grid>
</UserControl>
